import { createApp } from 'vue'
import App from './App.vue'

const app = createApp(App);

//Antd
import Antd from "ant-design-vue";
import "ant-design-vue/dist/antd.css";
import * as Icons from "@ant-design/icons-vue";
app.use(Antd);

// //ElementPlus
// import ElementPlus from 'element-plus'
// import 'element-plus/dist/index.css'
// app.use(ElementPlus);

//vuex
import store from "./store/index";
app.use(store);

//解析函数
import explain from "./explain";
app.config.globalProperties.$explain = explain; //用$与组件内自定义的函数区分

//搜索dom节点
import searchDom from "./searchDom";
app.config.globalProperties.$searchDom = searchDom;

//存储路径
app.config.globalProperties.__filePath = `./easyWebsite`;

const icons: { [organName: string]: any } = Icons;
for (const i in icons) {
  app.component(i, icons[i]);
}

app.mount('#app');